<div class="advertisements index">
    <div class="header-banner">
	<h1>
    	<?php __('Banners');?>
		<div class="add-new-item">
		<?php echo $this->Html->link($this->Html->image('assets/icons/dashboard/95.png', array('alt' => 'Edit')),
										'/admin/'.$this->params['controller']. '/' .'add',  
										array('escape' => false, 'class'=>'tooltip table_icon', 'title' => __('Add New Banner',true)));
		?>
        </div>
	</h1>
    </div>
	<table class = "normal">
	<thead>
		<tr>
				<th><?php __('Name');?></th>
				<th><?php __('Status');?></th>
				<th><?php __('Size');?></th>
				<th class="actions"><?php __('Actions');?></th>
		</tr>
	</thead>
	<tbody>
	<?php
	$i = 0;
	foreach ($advertisements as $advertisement):
		$class = null;
		if ($i++ % 2 == 0) {
			$class = ' class="altrow"';
		}
	?>
	<tr<?php echo $class;?>>
		<td><?php echo $advertisement['Banner']['name']; ?>&nbsp;</td>
		<td><?php echo $advertisement['Banner']['status']; ?>&nbsp;</td>
		<td><?php echo $advertisement['Banner']['size']; ?>&nbsp;</td>
		<td class="actions">
				<?php echo $this->Html->link($this->Html->image('assets/icons/actions_small/Pencil.png', array('alt' => 'Edit')),
												'/admin/'.$this->params['controller']. '/' .'edit'.'/'.$advertisement['Banner']['id'].'/1',  
												array('escape' => false, 'class'=>'tooltip table_icon'));
				?>
				<?php echo $this->Html->link($this->Html->image('assets/icons/actions_small/Trash.png', array('alt' => 'Delete')),
												'/admin/'.$this->params['controller']. '/' .'delete'.'/'.$advertisement['Banner']['id'],  
												array('rel' => 'delete', 'escape' => false, 'class'=>'tooltip table_icon'));
				?>
		</td>
	</tr>
<?php endforeach; ?>
</tbody>